<!--<?php
require_once template('header'); 
print <<<EOT
<!-- 左边开始 -->
<script type="text/javascript" src="include/javascript/jquery.jqzoom.min.js"></script>
<script type="text/javascript" src="$imgpath/tabs.js"></script>
<script type="text/javascript">
$(document).ready(function(){
//放大镜
$(".jqzoom").jqueryzoom({
				xzoom: 300, //zooming div default width(default width value is 200)
				yzoom: 300, //zooming div default width(default height value is 200)
				offset: 60, //zooming div default offset(default offset value is 10)
				position: "right", //zooming div position(default position value is "right")
 				preload:1,
				lens:1
			});
//购买
$("#add_cart").click(function(e){
$.ajax({
   type: "POST",
   url: "cart.php?per=ajax",
   cache:false,
   dataType:'json',
   data: $('#goods :input').serialize(),
   success: function(json){
     $("#show_cart").show();
     $("#show_cart").html('<div id="gm"><h3>您的购物车内共有 <strong>'+json.nums+'</strong> 件商品，合计： <strong>'+json.price+'</strong></h3><p> <a href="$mm_url[cart]">去收银台</a> <a href="javascript:;" onclick="\$(\'#show_cart\').hide();">继续购物</a></p></div>');
   },
   complete: function() {
     // $.unblockUI();
   }
});
});
});
</script>
<style type="text/css">
<!--
.jqzoom {
	float:left;
	position:relative;
	border:1px solid #ccc;
	padding:0px;
	margin-left: 76px !important;
	margin-left: 38px;
	cursor:pointer;
}
.jqzoom img { float:left; }
div.zoomdiv {
	z-index:100;
	position:absolute;
	top:0px;
	left:0px;
	width:200px;
	height:200px;
	background:#fff;
	border:1px solid #ddd;
	display:none;
	text-align:center;
	overflow:hidden;
}
div.jqZoomPup {
	z-index:10;
	visibility:hidden;
	position:absolute;
	top:0px;
	left:0px;
	width:50px;
	height:50px;
	border:1px solid #aaa;
	background: #fff url($imgpath/zoom.gif) 50% top  no-repeat;
	opacity:0.5;
	-moz-opacity:0.5;
	-khtml-opacity:0.5;
	filter:alpha(Opacity=50);
}
#gm {
	border: 1px solid #f60;
	padding: 8px 10px;
	text-align: center;
}
#gm h3 {
	font-weight: normal;
	font-size: 12px;
	margin-bottom: 8px;
}
#gm h3 strong {
	color: #f60;
	font-size: 12px;
}
#gm p a {
	background: #f00;
	color: #fff;
	padding: 3px 10px 1px 10px;
	margin: 0 4px;
}
.tabs{
	clear:both;
	margin:14px 20px auto 20px;
	cursor: pointer;
	height: 100%;
	overflow: hidden;
}
.tabs a{
	display:block;
	float:left;
	background:url($imgpath/tabs_right.gif) right -22px;
	margin-right: 2px;
}
.tabs a span{
	background:url($imgpath/tabs_left.gif)  no-repeat left -22px;
	padding:5px 9px 0 9px;
	display:block;
	float:left;
	color:#666;
	height:17px;
	white-space:nowrap;
}
.tabs a.curtab{
	display:block;
	float:left;
	background:url($imgpath/tabs_right.gif) right top;
}
.tabs a.curtab span{
	background:url($imgpath/tabs_left.gif) no-repeat left top;
	padding:5px 9px 0 9px;
	display:block;
	float:left;
	color:#000;
	font-size:12px;
}
.tabcontent{
	clear: both;
	margin: 2px 20px;
	border: 1px solid #ddd;
	padding: 8px;
	height: 100%;
	overflow: hidden;
}
-->
</style>
	<!-- 左边开始 -->
	<div id="left">
		<p><img src="$imgpath/left_menu_title.gif" /></p>
		<div id="login">
<!--
EOT;
if($m_check_id){
print <<<EOT
-->	
			<p>$lang[welcome]：$m_check_id
<!--
EOT;
if($mm_adminid==1){
print <<<EOT
-->
			<a href="admincp.php?module=index" target="_blank">[$lang[admin]]</a>
<!--
EOT;
} print <<<EOT
-->
			</p>
			<p><a href="$mm_url[logout]"><u>[$lang[logout]]</u></a> | <a href="member.php?action=profile"><u>[$lang[client_user]]</u></a></p>		
			<p>$lang[show_point]：<span>$m_check_point</span></p>
			<p>$lang[show_money]：<span>$m_check_money</span></p>
<!--
EOT;
} else { 
print <<<EOT
-->
			<form method="post" action="logging.php?action=login" name="mvmmall_main_login" onsubmit="javascript:return check_main_login()">
			<input type="hidden" name="referer" value="$referer">
			<input type="hidden" name="setp" value="1">
			<p>$lang[user_id] : <input name="login_id" type="text" maxlength="40" class="inp" /></p>
			<p>密&nbsp;&nbsp;&nbsp;码 : <input name="login_pass" type="password" maxlength="40" class="inp" /></p>
			<input type="hidden" name="code" value="$captcha">	
<!--
EOT;
if($mm_login_code==1 && $mm_close==1){
print <<<EOT
-->
			<p><img src="ajax.php?action=code" onclick=this.src="ajax.php?action=code&"+Math.random() align="absmiddle" style="cursor: pointer;" title="$lang[click_captcha]" /> <input name="code" onkeyup="pressCaptcha(this)" type="text" class="inp" id="code" maxlength="8" /> </p>
<!--
EOT;
} print <<<EOT
-->			
			<p><input name="提交" type="image" src="$imgpath/login.gif" /> <a href="$mm_url[user_reg]"><img src="$imgpath/login_b.gif" /></a></p>	
			</form>
<!--
EOT;
} print <<<EOT
-->				
		</div>
		<!--用户登录结束-->

		<!-- 商品分类开始 -->
		<h3 class="le3"><img src="$imgpath/left_menu_01.gif" /></h3>
		<div class="le2">
			<!--
EOT;
foreach ($cat_parent as $val){
print <<<EOT
-->
			<dl class="fl">
				<dt><a href="$val[url]">$val[title]</a></dt>
<!--
EOT;
foreach ($val[children] as $child){
print <<<EOT
-->
				<dd><a href="$child[url]">- $child[title]</a></dd>
<!--
EOT;
} print <<<EOT
-->	
			</dl>
<!--
EOT;
} print <<<EOT
-->		
			<p><img src="$imgpath/left_menu_03.gif" /></p>
		</div>
		<!-- 商品分类结束 -->
			
			
		<!-- 相关文章开始 -->
		<h3 class="le3"><img src="$imgpath/left_menu_05.gif" /></h3>
		<div class="le2">
			<ul class="le22">	
<!--
EOT;
foreach ($art_list as $val){
print <<<EOT
-->					
				<li><a href="$val[url]" title="$val[title]">$val[subject]</a></li>
<!--
EOT;
} print <<<EOT
-->		
			</ul>
		</div>
		<div class="title_b"><p></p></div>
		<!-- 相关文章结束 -->
		
		<!-- 已经浏览开始 -->
		<h3 class="le3"><img src="$imgpath/left_menu_04.gif" /></h3>
		<div class="le2">	
<!--
EOT;
if($mm_history_type==1){
print <<<EOT
-->
			<ul id="over">
<!--
EOT;
foreach ($history as $val){
print <<<EOT
-->			
				<li onmouseover="this.style.filter='Alpha(Opacity=60)';" onmouseout="this.style.filter='';"><a href="$val[url]"><img src="$val[photo]" alt="$val[title]" /></a></li>
<!--
EOT;
} print <<<EOT
-->				
			</ul>
<!--
EOT;
} else { print <<<EOT
-->	
			<ul id="over1">
<!--
EOT;
foreach ($history as $val){
print <<<EOT
-->	
				<li><span>&raquo;</span><a href="$val[url]" title="$val[title]">$val[subject]</a></li>
<!--
EOT;
} print <<<EOT
-->	
			</ul>
<!--
EOT;
} print <<<EOT
-->			
		</div>
		<div class="title_b"><p></p></div>
		<!-- 已经浏览结束 -->

	</div>
	<!-- 左边结束 -->
	<!-- 右边开始 -->
	<div id="right">
		<div id="location"><p><b>$navigation</b></p></div>
		$show_goods_head
		<div class="shop_xg">
			<div class="title8"><span>$product[title] $product[addoption] <b>$product[free_delivery]</b></span></div>
			<div id="shop_dr1">
				<p class="jqzoom"><img src="$product[goods_file2]"  jqimg="$product[goods_file2]"  width="$mm_img_width" height="$mm_img_height" /></p>
				<p style="clear:both; padding-top:10px;"><a href="$product[img_url]" target="_blank"><img src="$imgpath/zoom1.gif" /></a></p>
			</div>
			<div id="shop_dl1">
				<form name="goods" id="goods" method="post" action="">
				<input type="hidden" name="ps_goid" id="ps_goid" value="$product[uid]">
				<input type="hidden" name="ps_select" id="ps_select" value="c">
				<p><b>$lang[event_priceb]：</b><strong>$product[goods_market_price]</strong></p>
				<p><b>$lang[buy_price]：</b><span>$product[goods_sale_price]</span></p>
<!--
EOT;
foreach ($other_price as $val){
print <<<EOT
-->
				<p><b>$val[title]：</b><span>$val[price]</span></p>
<!--
EOT;
} print <<<EOT
-->
	             <p><b>$lang[integral]：</b>$product[goods_point] $lang[point]</p>
				 <p><b>$lang[code]：</b>$product[goods_code]</p>
				 <p><b>$lang[kg]：</b>$product[goods_kg]  kg</p>
				 <p><b>$lang[brand]：</b>$product[goods_brand]</p>
				<!-- 属性价格开始 -->
<!--
EOT;
foreach ($attval_cart as $list){
print <<<EOT
-->
				<p><b>$list[name]：</b>
<!--
EOT;
foreach ($list[value] as $val ){
print <<<EOT
-->
				<input name="att_value[$val[bute_id]]"  id="att_value[$val[bute_id]]" type="radio" value="$val[att_id]"> $val[title]( + $val[price])
<!--
EOT;
} print <<<EOT
-->				
				</p>
<!--
EOT;
} print <<<EOT
-->
<!-- 属性价格结束 -->
         
<!-- 商品扩展属性开始 -->
<!--
EOT;
foreach ($attvalue as $val){
print <<<EOT
-->
				
				<p><b>$val[att_name]：</b>$val[att_value]</p>
<!--
EOT;
} print <<<EOT
-->
<!-- 商品扩展属性结束 -->
				<p class="xj1"><b>$lang[buy_number]：</b><input name="ps_num" id="ps_num" type="text" align="absmiddle" value="1" class="inp" size="1" /></p>
				<p class="xj1"><img src="$imgpath/arrow_xc.gif" align="absmiddle"> <input maxlength="255" class="inp" size="34" value="$product[web_url]" name="url"> <input type="button" value="$lang[copy]" class="btn2" onclick="HighlightAll(this.form.url)"></p>
				<div style="padding-top:8px;"><a href="javascript:;" id="add_cart" ><img src="$imgpath/btn_car.gif" /></a> <a href="javascript:sendcart(document.getElementsByName('goods')[0],'S');"><img src="$imgpath/btn_fav.gif" /></a> <a href="mailer.php?action=recommend&uid=$product[uid]" target="_blank"><img src="$imgpath/services.gif" /></a></div>
			     <div class="clear"></div>
				<div id="show_cart"></div>
				</form>
			</div>

			<div class="clear"></div>
			<div class="xxx" id="recom">
				<div class="tabs" id="recomtabs"><a class="tab curtab" id="tj1tab" onclick="javascript:setTab('recom','tj1');"><span>$lang[explain]</span></a> <a class="tab" id="tj2tab" onclick="javascript:setTab('recom','tj2');"><span>$lang[borderline]</span></a>
 <a class="tab" id="tj3tab" onclick="javascript:setTab('recom','tj3');"><span>$lang[tag]</span></a>
  <a href="#pl" style="text-decoration:none; cursor:pointer;"><span>相关评论</span></a></div>
				<div class="tabcontent" id="tj1">
					<div class="tjj">$product[conter]</div>
				</div>
				<div class="tabcontent" id="tj2" style="display: none">		
<!--
EOT;
if (count($other_goods)>0){
print <<<EOT
-->
<!--相关产品开始-->
				<ul class="xgsp">
<!--
EOT;
foreach ($other_goods as $val){
print <<<EOT
-->			
					<li>
						<p class="img"><a href="$val[url]"><img src="$val[photo]" width="$cf_indexw" height="$cf_indexh" alt="$val[title]" /></a></p>
						<p class="sn"><a href="$val[url]" title="$val[title]">$val[title]</a></p>
						<p class="sp">$lang[buy_price]：<span>$val[goods_sale_price]</span></p>
						<p>$lang[code]：$val[goods_code]</p>
					</li>
<!--
EOT;
} print <<<EOT
-->				</ul>	
<!--相关产品结束-->
<!--
EOT;
} print <<<EOT
-->	
				</div>
				<div class="tabcontent" id="tj3" style="display: none">
				<ul class="sybq">
<!--
EOT;
foreach ($goods_tag as $val){
print <<<EOT
-->					
					<li>$val[tag_name]</li>
<!--
EOT;
} print <<<EOT
-->	
				</ul>
				<form action="tag.php" method="post" name="tag">
				<input type="hidden" name="action" value="write" />
				<input type="hidden" name="goods_id" value="$product[uid]" />
				<p class="xxym1"><input name="tag_name" class="inp" type="text" maxlength="120" /> <input name="" class="btn2" value="$lang[add_tag]" type="Submit"/></p>
				</form>
				</div>
			</div>
			
			<fieldset>
				<legend>$lang[comment]</legend>		
				
				<div class="xgpl1">
					<h5><a href="$product[com_url]" target="_blank">$lang[all_comment]</a>$lang[new_comment]</h5>
<!--评论数据循环开始-->
<!--
EOT;
foreach ($comment as $val) {
print <<<EOT
-->	  
					<dl>
						<dt><span>$lang[write_date]：$val[date] </span>$lang[shop_user]：<b>$val[name]</b> [$val[comment_id]] $lang[comment_star]：<b>$val[star]</b></dt>
						<dd><a href="comment.php?action=reply&uid=$val[uid]" style="float:right;">[$lang[uesr_reply]]</a>$lang[subject]：<b>$val[title]</b></dd>
						<dd style="padding-left:36px; padding-right:25px;">$val[conter]</dd>
<!--
EOT;
if ($val[reply]!='') {
foreach ($val[reply] as $list){   
print <<<EOT
-->	 						
						<dd class="hf">
							<h3>$list[user_name] [$list[user_id]]  $list[reply_date]</h3>
							<p>$list[reply_body]</p>
						</dd>					
<!--
EOT;
}} print <<<EOT
-->	
					</dl>
<!--
EOT;
} print <<<EOT
-->				
				</div>
				
				<a name="pl"></a><form action="comment.php" method="post" name="mvmmall_comment" class="xg2">
				<input type="hidden" name="ps_mode" value="comment_write">
				<input type="hidden" name="ps_goid" value="$product[uid]">
				<div class="xg1"><span>$lang[comment_msg]</span>$lang[send_comment]
<!--
EOT;
if($mm_comment_code==1){
print <<<EOT
-->
				$lang[captcha]：<input name="code" onkeyup="pressCaptcha(this)" type="text" class="text" id="code" size="6" maxlength="8" />  <img src="ajax.php?action=code" onclick=this.src="ajax.php?action=code&"+Math.random() align="absmiddle" style="cursor: pointer;" title="$lang[click_captcha]" />
<!--
EOT;
} print <<<EOT
-->	
				</div>
				<p>$lang[subject]： <input name="subject" type="text" class="text" size="85" /></p>
				<p>$lang[comment_star]：<input id="rate_0" type="radio" name="comment_star" value=" 5" checked="checked"/><IMG alt="" src="$imgpath/Egg_5.gif">
					<input  type="radio" name="comment_star" value="4" /><IMG alt="" src="$imgpath/Egg_4.gif">
					<input type="radio" name="comment_star" value="3"/><IMG alt="" src="$imgpath/Egg_3.gif">
					<input  type="radio" name="comment_star" value="2"/><IMG alt="" src="$imgpath/Egg_2.gif">
					<input type="radio" name="comment_star" value="1" /><IMG alt="" src="$imgpath/Egg_1.gif"></p>
				<p><textarea name="comment_body" cols="70" class="text" rows="8"></textarea></p>
				<p><input class="btn2" type="submit" value="$lang[wite_announce]" /> <input type="reset" value="$lang[reset]" class="btn2" /></p>
				</form>
			</fieldset>
			$show_goods_foot
		</div>
		<div class="title_b"><p></p></div>
	</div>
	<!-- 右边结束 -->
<!--
EOT;
?>-->